//
//  IGiGalleryPushApi.m
//  jingdongfang
//
//  Created by BOE on 2017/9/6.
//  Copyright © 2017年 LJL. All rights reserved.
//

#import "IGiGalleryPushApi.h"

@interface IGiGalleryPushApi()
    
@property (nonatomic, strong) NSArray *macIds;                      ///>设备的mac地址
@property (nonatomic, strong) NSArray *pIds;                        ///>推送图片的列表

@end

@implementation IGiGalleryPushApi

- (id)initWithMacIds:(NSArray *)macIds pIds:(NSArray *)pIds {
    self = [super init];
    if (self) {
        self.macIds = macIds;
        self.pIds = pIds;
    }
    return self;
}

- (NSString *)requestUrl {
    return @"push/push.action";
}
    
- (id)requestArgument {
    return @{
             @"macIds": [self arrToJsonString:self.macIds],
             @"pIds": [self arrToJsonString:self.pIds],
             @"text": _text==nil?@"":_text,
             @"isTPush": _isTPush==nil?@"0":_isTPush,
             @"uId":[IGUser getUid]
             };
}
    
- (NSString *)arrToJsonString:(NSArray *)arr {
    NSString *arrStr = [arr componentsJoinedByString:@","];
    return [NSString stringWithFormat:@"[%@]", arrStr];
}

@end

@implementation IGiGalleryPushModel : IGBaseModel
    
@end

@implementation IGiGalleryPushResp : IGBaseResp

@end
